﻿using System;

namespace UnityEngine.UI
{
	// Token: 0x02000670 RID: 1648
	public abstract class RepeatIntervalButton : UnityEngine.UI.RepeatButton
	{
		// Token: 0x17000419 RID: 1049
		// (get) Token: 0x06002703 RID: 9987 RVA: 0x0014A440 File Offset: 0x00148640
		// (set) Token: 0x06002704 RID: 9988 RVA: 0x0014A448 File Offset: 0x00148648
	    public bool isOn {  get;  set; }

		// Token: 0x06002705 RID: 9989 RVA: 0x0014A454 File Offset: 0x00148654
		public override void Process(bool push)
		{
			if (push)
			{
				this.isOn = (this.timer == 0f || this.timer == this.interval);
				this.timer += Time.deltaTime;
				this.timer = Mathf.Min(this.timer, this.interval);
			}
			else
			{
				this.isOn = false;
				this.timer = 0f;
			}
			if (!base.IsSelect)
			{
				this.isOn = false;
			}
		}

		// Token: 0x04002DF6 RID: 11766
		[SerializeField]
		public float interval = 0.5f;

		// Token: 0x04002DF7 RID: 11767
		public float timer;
	}
}
